package com.mes.biz.service.impl;

import java.util.List;
import org.springframework.stereotype.Service;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import com.github.pagehelper.PageInfo;
import com.mes.common.core.domain.BaseEntity;
import com.mes.common.core.service.BaseServiceImpl;
import com.mes.biz.mapper.BizPaymentBillMapper;
import com.mes.biz.domain.BizPaymentBill;
import com.mes.biz.service.BizPaymentBillService;
import org.springframework.transaction.annotation.Transactional;

/**
 * 收款单订单明细Service业务层处理
 * @author wy
 * @email wy
 * @date 2023-07-10
 */
@Service
@Transactional(readOnly = true)
public class BizPaymentBillServiceImpl extends BaseServiceImpl<BizPaymentBillMapper, BizPaymentBill> implements BizPaymentBillService {

    private static final Logger log = LoggerFactory.getLogger(BizPaymentBillServiceImpl.class);

    /**
     * 获取单条数据
     * @param bizPaymentBill 收款单订单明细
     * @return 收款单订单明细
     */
    @Override
    public BizPaymentBill get(BizPaymentBill bizPaymentBill) {
        BizPaymentBill dto = super.get(bizPaymentBill);
        return dto;
    }

    /**
     * 获取单条数据
     * @param id 收款单订单明细id
     * @return 收款单订单明细
     */
    @Override
    public BizPaymentBill get(String id) {
        BizPaymentBill dto = super.get(id);
        return dto;
    }

    /**
     * 查询收款单订单明细列表
     * @param bizPaymentBill 收款单订单明细
     * @return 收款单订单明细
     */
    @Override
    public List<BizPaymentBill> findList(BizPaymentBill bizPaymentBill) {
		List<BizPaymentBill> bizPaymentBillList = super.findList(bizPaymentBill);
        return bizPaymentBillList;
    }

    /**
     * 分页查询收款单订单明细列表
     * @param bizPaymentBill 收款单订单明细
     * @return 收款单订单明细
     */
    @Override
    public PageInfo<BizPaymentBill> findPage(BizPaymentBill bizPaymentBill) {
		PageInfo<BizPaymentBill> page = super.findPage(bizPaymentBill);
        return page;
    }

    /**
     * 保存收款单订单明细
     * @param bizPaymentBill
     * @return 结果
     */
    @Override
    public boolean save(BizPaymentBill bizPaymentBill) {
        return super.save(bizPaymentBill);
    }

    /**
     * 删除收款单订单明细信息
     * @param bizPaymentBill
     * @return 结果
     */
    @Override
    public boolean remove(BizPaymentBill bizPaymentBill) {
        return super.remove(bizPaymentBill);
    }

    /**
     * 批量删除收款单订单明细
     * @param ids 需要删除的收款单订单明细ID
     * @return 结果
     */
    @Transactional(readOnly = false)
    @Override
    public int deleteBizPaymentBillByIds(String[] ids) {
        return mapper.deleteBizPaymentBillByIds(ids, BaseEntity.DEL_FLAG_DELETE);
    }

    @Transactional(readOnly = false)
    @Override
    public int deleteBizPaymentBillByPaymentId(String paymentId) {
        return mapper.deleteBizPaymentBillByPaymentId(paymentId, BaseEntity.DEL_FLAG_DELETE);
    }

    @Override
    public List<BizPaymentBill> selectByPaymentId(String paymentId) {
        return mapper.selectByPaymentId(paymentId);
    }

}
